package com.CityHunter.StaticObject;

import java.util.ArrayList;

import com.CityHunter.DataObject.Schedule;

public class SharedReference {

	private ArrayList<Schedule> schedules;
	
	public SharedReference(){
		
	}
	
	public void addSchedule(Schedule schedule){
		schedules.add(schedule);
	}
	
	public Schedule getSchedule(int scheduleId){
		Schedule s = new Schedule();
		
		for (int i=0;i<schedules.size();i++){
			if (schedules.get(i).getScheduleId() == scheduleId)
				s = schedules.get(i);
		}
		
		return s;
	}
	
}
